import Vue from 'vue';
import VueRouter from 'vue-router';
import app from './App.vue'
import axios from 'axios'
Vue.use(VueRouter)
import router from './router.js'
import { Header } from 'mint-ui';
import { Swipe, SwipeItem,Button } from 'mint-ui';
import moment from 'moment'
Vue.component(Swipe.name, Swipe);
Vue.component(SwipeItem.name, SwipeItem);
Vue.component(Button.name,Button)
// 要按需导入的话 要装一个babel-plugin-component的babel插件
Vue.component(Header.name, Header);
axios.defaults.baseURL = "http://www.liulongbin.top:3005/"
// 给axios设置全局参数
Vue.prototype.$http = axios;
import './lib/mui/css/mui.css'
import './lib/mui/css/icons-extra.css'
// 创建vm实例

Vue.filter('dateFormat',function(msg){
     return moment(msg).format('YYYY-MM-DD HH:mm:ss')
})

const vm = new Vue({
    el:'#app',
    components:{
        app
    },
    router,
    render:c=>c(app)
})